<template lang="pug">
  .underbanner(v-if="show")
    a(:href="data.linkUrl")
      img(:src="data.picUrl | imgUrl", alt="")
</template>
<script>
export default {
  data () {
    return {
      show: true,
      data: {}
    }
  },
  props: ['cdata'],
  created () {
    if (!this.cdata[0].tag) {
      this.show = false
      return
    }
    if (this.cdata[0].tag.length == 0) {
      this.show = false
      return
    }
    this.data = this.cdata[0].tag[0]
  }
}
</script>
<style lang='scss' scoped>
.underbanner {
    a {
        display: block;
        width: to_rem(750px);
        height: to_rem(326px);
        img {
            width: 100%;
            height: 100%;
        }
    }
}
</style>
